package com.huluwa.jczq.common;

import com.google.gson.Gson;
import com.google.gson.GsonBuilder;
import jdk.internal.dynalink.beans.StaticClass;
import org.apache.log4j.Logger;

import java.util.HashMap;
import java.util.Map;

public class Constant {
	/**
	 * 运行日志，可以往里面记录所有业务的运行日志
	 */
	public static final Logger runLog = Logger.getLogger("run.log");
	public static final Logger debugLog = Logger.getLogger("debug.log");
	/**
	 * 环境相关信息
	 */
	public static final HashMap<String,String> STABLE_TASK = new HashMap<String,String>();
	static{
		STABLE_TASK.put("host","172.16.36.155");
		STABLE_TASK.put("port","8822");
		STABLE_TASK.put("username","wangzheng1");
		STABLE_TASK.put("password","r3faX]Tw");
	}
	public static final HashMap<String, HashMap<String,String>>  REMOTE_ENV_MAP= new HashMap<String, HashMap<String,String>>();
	static {
		REMOTE_ENV_MAP.put("STABLE_TASK",STABLE_TASK);
	}

	/**
	 * 日志路径
	 */

	public static final  String TASK_LOG_DIR = "/home/wangzheng1/lottery.log.2018-06-21-18";
	/**
	 * 通过key定位lottery日志中报文位置
	 */
	public static final String BET_SELECTOR_KEY = "【http send】";
	public static final String RESEND_SELECTOR_KEY = "【http receive】";
	public static final String NOTIFY_SELECTOR_KEY = "【http receive】";

	/**
	 * 各个合作方的selector，根据ticket定位
	 * XXXBetSeletor:合作方投注报文定位
	 * XXXResendSeletor:合作方返回通知报文定位
	 * XXXNotifySeletor:合作方主动通知报文定位
	 * 占位符：{ticketId}
	 */
	/**
	 * 耀森票号信息定位
	 */
	public static final String yaosenBetSelector = "";
	public static final String yaosenResendSelector = "//ticket[ordersID='{ticketId}']";
	public static final String yaosenNotifySelector="";
	/**
	 * 测试合作方json selector
	 */
	public static  final  String testBetSelector = "$.body.matchTicketRequest.ticket[OrderId='{ticket}']";


}
